package cn.zwx.distributed.svc.domain.enums;

/**
 * @author zhangwenxue
 */
public enum DistributedCodeEnum {
    /**
     * 成功
     */
    GENERATE_ID_ERROR(30001,"生成Id异常"),
    CLOCK_MOVED_BACKWARDS_ERROR(30002,"Clock moved backwards. Refusing "),
    TIMESTAMP_BITS_EXHAUSTED_ERROR(30002,"Timestamp bits is exhausted. Refusing UID generate");

    private final int code;
    private final String msg;

    DistributedCodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }
}
